package  
{
	import flash.display.*;
	import flash.geom.*;
	import iso.*;
	
	/**
	 * Iso 空间转换
	 * @author StefanieKaka
	 */
	public final class IsoTransformTest extends Sprite 
	{
		
		public function IsoTransformTest() 
		{
			var p0 : Point3D = new Point3D();
			var p1 : Point3D = new Point3D(100, 0, 0);
			var p2 : Point3D = new Point3D(100, 0, 100);
			var p3 : Point3D = new Point3D(0, 0, 100);
			
			var sp0 : Point = IsoUtils.isoToScreen(p0);
			var sp1 : Point = IsoUtils.isoToScreen(p1);
			var sp2 : Point = IsoUtils.isoToScreen(p2);
			var sp3 : Point = IsoUtils.isoToScreen(p3);
			
			var tile : Sprite = new Sprite();
			tile.x = 200;
			tile.y = 200;
			this.addChild(tile);
			
			tile.graphics.lineStyle(0);
			tile.graphics.moveTo(sp0.x, sp0.y);
			tile.graphics.lineTo(sp1.x, sp1.y);
			tile.graphics.lineTo(sp2.x, sp2.y);
			tile.graphics.lineTo(sp3.x, sp3.y);
			tile.graphics.lineTo(sp0.x, sp0.y);
		}
		
	}

}

































///////////////////////////////////////////////////////////////////////////////////////////////////
// end file